var DBPost = function(){
  this.storageKeyName = 'poemContent';
};

DBPost.prototype = {
  getAllPostData : function(){
    var res = wx.getStorageSync(this.storageKeyName);
    if(!res){
      res = require('../data/data.js').poemContent;
      wx.setStorageSync('poemContent', res);
    }
    return res;
  },

  execSetStorageSync : function(data){
    wx.setStorageSync(this.storageKeyName,data);
  }

};

module.exports = {
  DBPost: DBPost 
};
